var express = require('express');
var router = express.Router();

/* GET home page. */
router.get('/', function(req, res, next) {
  // const p = req.cookies.power
  const p = req.session.power
  if(p < 1){
    res.render('order', {
      index: 3,
      power: p
    });
  }else{
    res.render('error');
  }
});

module.exports = router;
